Class CustomEffect<T>
Custom effect for OdinNative.Wrapper.MediaPipeline callbacks
Assembly: cs.temp.dll.dll
Inheritance: System.Object
-> OdinNative.Wrapper.Media.PiplineEffect
Implements:
OdinNative.Wrapper.Media.IPiplineEffect
Methods
Insert(uint, PipelineCallback<T>, T)
Add a OdinNative.Wrapper.Media.CustomEffect
to OdinNative.Wrapper.Media.PiplineEffect.Parent pipline.
Returns
System.UInt32
: effect id
Parameters
Type | Name | Description |
---|---|---|
System.UInt32 | index | effect index in pipeline |
Odin.PipelineCallback<<T>> | callback | effect event |
<T> | userData | Will be passed to callback with OdinNative.Wrapper.Media.CustomEffect |
SerializeUserdata(T)
Serialize arbitary userdata
Returns
System.Byte[]
: byte array representation of userdata value
Parameters
Type | Name | Description |
---|---|---|
<T> | value | byte array data of value |
SerializeUserdata(T, bool)
Serialize arbitary userdata
Returns
Odin.IntPtr
Parameters
Type | Name | Description |
---|---|---|
<T> | value | object data of value |
System.Boolean | destroy | true to call the DestroyStructure(IntPtr, Type) method. |
DeserializeUserdata(byte[])
Deserializes userdata from a byte array
Returns
<T>
: Instance of OdinNative.Wrapper.Media.CustomEffect
Parameters
Type | Name | Description |
---|---|---|
System.Byte[] | data | custom userdata |
DeserializeUserdata(IntPtr)
Deserializes userdata from a pointer
Returns
<T>
: Instance of OdinNative.Wrapper.Media.CustomEffect
Parameters
Type | Name | Description |
---|---|---|
Odin.IntPtr | ptr | pointer |
Create(MediaPipeline, PipelineCallback<T>, T)
Insert a custom effect in the specified pipline
Returns
OdinNative.Wrapper.Media.CustomEffect<T>: Instance of OdinNative.Wrapper.Media.CustomEffect
Parameters
Type | Name | Description |
---|---|---|
OdinNative.Wrapper.MediaPipeline | pipeline | where to create a vad effect |
Odin.PipelineCallback<<T>> | callback | delegate reference for effect event |
<T> | userData | custom userdata Marshal.StructureToPtr |
Serialize(T)
Serialize structure to pointer for arbitary data
Returns
System.Byte[]
: byte array representation of data structure
Parameters
Type | Name | Description |
---|---|---|
<T> | value | data |
Serialize(T, bool)
Serialize structure to pointer for arbitary data
Returns
Odin.IntPtr
: pointer of data structure
Parameters
Type | Name | Description |
---|---|---|
<T> | value | data |
System.Boolean | destroy | free value |
Deserialize(byte[])
Deserializes a structure from a byte array
Returns
<T>
: structure
Parameters
Type | Name | Description |
---|---|---|
System.Byte[] | data | binary data to deserialize |
Deserialize(IntPtr)
Deserializes a structure from a pointer
Returns
<T>
: structure
Parameters
Type | Name | Description |
---|---|---|
Odin.IntPtr | ptr | pointer to deserialize as structure |